class CreateOperationLogs < ActiveRecord::Migration
  def change
    create_table :operation_logs do |t|
      t.references :user, index: true, foreign_key: true
      t.string :name, index: true
      t.string :code, index: true
      t.string :message
      t.string :req_url
      t.string :req_method
      t.string :req_ip
      t.text :req_params
      t.string :module
      t.string :operation
      t.integer :res_status

      t.timestamps null: false
    end
  end
end
